<template>
  <view class="uni_combox_wapper">
    <uni-combox
      :label="label"
      :placeholder="placeholder"
      :candidates="candidates"
      :value="value"
      @input="onInput"
    />
  </view>
</template>

<script>
import { uniCombox } from "@dcloudio/uni-ui";

export default {
  components: {
    uniCombox,
  },
  props: {
    value: {
      type: String,
      default: undefined,
    },
    candidates: {
      type: [Array, null],
      default: [],
    },
    label: {
      default: "",
    },
    placeholder: {
      default: "请进行选择",
    },
  },
  data() {
    return {};
  },
  methods: {
    onInput(value) {
      this.$emit("update:value", value);
    },
  },
};
</script>

<style lang="scss" scoped>
.uni_combox_wapper {
  z-index: 1;
}
</style>